//
//  MbochureMainView.m
//  Zinipad
//
//  Created by ZeLkOvA on 12. 5. 24..
//  Copyright (c) 2012년 __MyCompanyName__. All rights reserved.
//

#import "MbochureMainView.h"

@interface MbochureMainView ()

@end

@implementation MbochureMainView
@synthesize myPDFView;

- (id)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil
{
    self = [super initWithNibName:nibNameOrNil bundle:nibBundleOrNil];
    if (self) {
        // Custom initialization
    }
    return self;
}

- (void)viewDidLoad
{
    [super viewDidLoad];
    CGRect frame = CGRectMake(0, 0, 1024, 768);
    myPDFView = [[viewPDF alloc] initWithFrame:frame FileName:@"ZIN_TABLETAPP_V0.1_20120517"];
    [self.view addSubview:myPDFView];
    
    UIButton* CloseButton = [UIButton buttonWithType:UIButtonTypeRoundedRect];
    [CloseButton setFrame:CGRectMake(1024-50,10, 40, 40)];
    [CloseButton setTitle:[NSString stringWithFormat:@"매칭"] forState:UIControlStateNormal];
    [CloseButton setTitleColor:[UIColor blackColor] forState:UIControlStateNormal];
    [CloseButton setContentHorizontalAlignment:UIControlContentHorizontalAlignmentLeft];
    [CloseButton setTitleEdgeInsets:UIEdgeInsetsMake(5, 10, 5, 5)];
    [CloseButton addTarget:self action:@selector(CloseButtonPressed:) forControlEvents:UIControlEventTouchUpInside];
    [self.view  addSubview:CloseButton];

}
-(void)CloseButtonPressed:(id)sender
{
    [self.navigationController popViewControllerAnimated:YES];
}

- (void)viewDidUnload
{
    [super viewDidUnload];
    // Release any retained subviews of the main view.
}

- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation
{
    return (interfaceOrientation == UIInterfaceOrientationPortrait);
}

@end
